package com.bybops.model.bean;

import java.io.Serializable;

/**
 * 设备列表javabean
 */
public class EquipmentList implements Serializable{

    /**
     * equipSN : 123
     * pollTime : 2
     * lockedUserKey :
     * hospitalId : 5bd2c4e89ea2d39b6a612404
     * reDate : 1540544664962
     * id : 5b2f62fa9ea2d39b6a3a9f31
     * barcode : 123456
     * lockName : 123
     * status : 1
     */

    public String barcode;  //设备条码
    public String hospital;  //分配医院
    public String department;  //分配部门
    public int equipStatus;   //锁的状态
    public String energy = "02";  //锁的电量
    public long pollTime;  //保修时间或者检修时间，格式为时间戳
    public String equipSN;
    public String lockedUserKey;
    public String hospitalId;
    public long reDate;
    public String id;
    public String lockName;
    public String userName;
    public String userKey;
    public long faultTime;  //故障报修的时间，毫秒
    public String faultDes;   //故障描述
    public String faultUrl;   //故障的图片url

    public int status;

    @Override
    public String toString() {
        return "EquipmentList{" +
                "barcode='" + barcode + '\'' +
                ", hospital='" + hospital + '\'' +
                ", department='" + department + '\'' +
                ", equipStatus=" + equipStatus +
                ", energy='" + energy + '\'' +
                ", pollTime=" + pollTime +
                ", equipSN='" + equipSN + '\'' +
                ", lockedUserKey='" + lockedUserKey + '\'' +
                ", hospitalId='" + hospitalId + '\'' +
                ", reDate=" + reDate +
                ", id='" + id + '\'' +
                ", lockName='" + lockName + '\'' +
                ", status=" + status +
                '}';
    }

    /**
     * 锁的状态
     */
    public interface LockStatus{
        //设备被某人临时锁定状态，待激活状态  用户正在下单中
        int LOCK = 8;
        //使用中
        int USERING = 10;
        //空闲状态
        int FREE = 1;
        //初始化状态 未投入使用
        int UNINT = 5;
        //无效设备
        int INVALID = 7;
        //设备故障
        int ERROR = -1;
    }
}
